<?php
    $xtpl_show      = new XTemplate("view/news/show.htm");
    
    $title      = "Thông tin khuyến mại";
    $id         = $_GET['id'];
    
    $sql        = "SELECT * FROM news WHERE id_n='" . $id . "'";
    $result     = mysql_query($sql);
    $row        = mysql_fetch_array($result);
    
    $xtpl_show  -> assign('title', $row['title']);
    $xtpl_show  -> assign('time', $row['time']);
    $xtpl_show  -> assign('content', $row['content']);
    $xtpl_show  -> assign('date', $row['date']);
    
    $xtpl_show      -> parse("SHOW");
    $content        = $xtpl_show -> text("SHOW");
?>